package com.fragment1;

import android.os.Bundle;

import com.alibaba.android.arouter.facade.annotation.Route;
import com.common.base.BaseFragment;
import com.common.event.TabSelectedEvent;
import com.common.route.RouterPath;
import com.fragment1.databinding.DiscoveryBinding;

import org.greenrobot.eventbus.EventBus;

@Route(path = RouterPath.DISCOVERY_FRAGMENT)
public class DiscoveryFragment extends BaseFragment<DiscoveryBinding> {

    @Override
    protected Class<DiscoveryBinding> getBindingClass() {
        return DiscoveryBinding.class;
    }

    @Override
    protected void initView(Bundle savedInstanceState) {
        binding.tvTitle.setText("发现");
        //菜单页面跳转
        binding.tvToFragment2.setOnClickListener(v -> {
            EventBus.getDefault().post(new TabSelectedEvent(3));
        });
    }

    @Override
    protected void loadData() {
        // 加载发现页数据
    }

    @Override
    public void onTabReselected() {
        // 刷新发现页
    }
}
